<?php 
defined('IN_ADMIN') or exit('No permission resources.');
include $this->admin_tpl('header', 'admin');?>
<link rel="stylesheet" type="text/css" href="<?php echo CSS_PATH?>iappadmin/iapppush.css"/>

<div class="pad-lr-10">
<fieldset>
	<legend>授权</legend>
	<p>推送授权信息：【<?php if($islogin=='yes'){?><span style="color:#090">已经授权，可以直接推送</span><?php }else{?><a href="?m=iappPush&c=manages&a=login&menuid=<?php echo $_GET['menuid']?>" style="color:#F00">未授权，签到点此授权</a> <?php }?> 】</p>
</fieldset>
<div class="bk15"></div>
<form method="post" action="?m=iappPush&c=manages&a=add">
	<div class="push">
	  <ul>
		<li>
		推送内容：<input type="text" class="input-text" name="info[title]" id="title" size="71" />
		</li>
		<li>
		推送参数：<input type="text" class="input-text" name="info[content]" id="content" size="71" />
		</li>
		</ul>
		<em onclick="getli()">选择</em>  
	</div>


<div class="bk15"></div>
<input type="submit" name="dosubmit" id="dosubmit" value="提交" class="button">&nbsp;<input type="reset" value="重写" class="button">
</form>

</div>

<script type="text/javascript">
window.top.$("#display_center_id").css("display","none");
function getli(){
	window.top.art.dialog(
	{
		id:'get_content',
		iframe:'index.php?m=iappPush&c=manages&a=getlist',
		title:'选择文章', 
		width:'720', 
		height:'360'
	}, 
	function(){
		var d = window.top.art.dialog({id:'get_content'}).data.iframe; 
		var str=d.$('#listdata').val();
		var arr = str.split("|");
		$("#title").val(arr[0]);
		$("#content").val('{"model":"'+arr[3]+'","modelid":"'+arr[4]+'","id":"'+arr[1]+'","catid":"'+arr[2]+'"}');
	}, 
	function(){
		window.top.art.dialog({id:'get_content'}).close()
	});
}
</script>
</body>
</html>